package com.fengmi.cms.controller;


import com.fengmi.cms.service.ICmsContentService;
import com.fengmi.entity.cms.CmsContent;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author 小马
 * @since 2021-10-12
 */
@RestController
@RequestMapping("/cms/cms-content")
public class CmsContentController {
    @Autowired
    private ICmsContentService cmsContentService;
    @RequestMapping("findContentByCatId/{catId}")
    public List<CmsContent> findContentByCatId(@PathVariable("catId")String catId){
        return cmsContentService.findContentByCatId(catId);
    }
}
